package com.shchuangzhi.smartguard.core;

/**
 * Created by j_hu on 7/22/17.
 */

public class CheckInOutResult {
    private boolean ok;
    private String voice;

    private CheckInOutResult(boolean ok, String voice) {
        this.ok = ok;
        this.voice = voice;
    }

    public boolean isOk() {
        return this.ok;
    }

    public String getVoice() {
        return this.voice;
    }

    public static CheckInOutResult ok() {
        return CheckInOutResult.ok("");
    }

    public static CheckInOutResult ok(String voice) {
        return new CheckInOutResult(true, voice);
    }

    public static CheckInOutResult fail(String voice) {
        return new CheckInOutResult(false, voice);
    }
}
